home *** CD-ROM | disk | FTP | other *** search
- property movieid, duration, movieLoc, movieRect
-
- on birth me
- set movieid to EMPTY
- set duration to EMPTY
- set movieLoc to EMPTY
- set movieRect to EMPTY
- return me
- end
-
- on QTPlay me
- if movieid <> EMPTY then
- qtmovie("Direct", movieid, "play")
- end if
- end
-
- on QTPause me
- if movieid <> EMPTY then
- qtmovie("Direct", movieid, "pause")
- end if
- end
-
- on QTDispose me
- if movieid <> EMPTY then
- qtmovie("Direct", movieid, "Dispose")
- set movieid to EMPTY
- set duration to EMPTY
- set movieLoc to EMPTY
- set movieRect to EMPTY
- end if
- end
-
- on QTIdle me
- qtmovie("Direct", movieid, "Idle")
- end
-
- on QTOpenMovie me, theFilePath, theRect
- qtmovie("OpenMovie", "Direct", theFilePath, "0,-480", "Invisible", "Paused")
- set movieid to the result
- qtmovie("Direct", movieid, "get", "duration")
- set duration to integer(the result)
- qtmovie("Direct", movieid, "set", "movieRect", theRect)
- set movieRect to theRect
- return movieid
- end
-
- on QTSetAudioLevel me, theLevel
- if movieid <> EMPTY then
- qtmovie("Direct", movieid, "set", "audioLevel", theLevel)
- end if
- end
-
- on QTSetRect me, theRect
- qtmovie("Direct", movieid, "set", "movieRect", theRect)
- end
-
- on QTSetCurrTime me, theTime
- qtmovie("Direct", movieid, "set", "currTime", theTime)
- end
-
- on QTSetTimeCallBack me, theHandle, theTime
- qtmovie("Direct", movieid, "set", "timedCallBack", theHandle && theTime)
- end
-
- on QTGetCurrtime me
- qtmovie("Direct", movieid, "get", "Currtime")
- return integer(the result)
- end
-
- on QTgetrect me
- qtmovie("Direct", movieid, "get", "movieRect")
- return the result
- end
-
- on QTGetLoc me
- qtmovie("Direct", movieid, "get", "movieLoc")
- set movieLoc to the result
- return movieLoc
- end
-
- on QTGetDuration me
- qtmovie("Direct", movieid, "get", "duration")
- set duration to integer(the result)
- return duration
- end
-
- on qtrefresh me
- if movieid <> EMPTY then
- qtmovie("Direct", movieid, "get", "movieLoc")
- qtmovie("Direct", movieid, "set", "movieLoc", the result)
- end if
- end
-
- on QTaway me
- end
-
- on QTreturn me
- end
-